package morning.cat.model;

import lombok.Data;
import org.springframework.beans.factory.config.AbstractFactoryBean;

/**
 * @describe: 类描述信息
 * @author: morningcat.zhang
 * @date: 2020/1/14 2:22 PM
 */
@Data
public class NonSingleToolFactory extends AbstractFactoryBean<Tool> {
	private int factoryId;
	private int toolId;

	public NonSingleToolFactory() {
		setSingleton(false);
	}

	@Override
	public Class<?> getObjectType() {
		return Tool.class;
	}

	@Override
	protected Tool createInstance() throws Exception {
		return new Tool(toolId);
	}
}